const baseUrl = 'http://localhost:8082'

// 封装一部网络请求函数
function request(options) {
	return new Promise((resolve, reject) => {
		uni.request({
			data: options.data || {},
			url:  baseUrl + options.url,
      method: options.method || 'GET',
      success(res){
        resolve(res.data)
      },
      fail:reject
		})
	})
}
export default request
